#include "RadianAir.h"
//--------------------------------------------------------------------------
RadianAir::RadianAir(QWidget* parent)
	:m_FullResCount(0)
	,m_ResLoaded(0)
	,QDialog(parent)
{
	setupUi(this);
	this->setWindowFlags(Qt::SplashScreen);
	labelLoadingInfo->setText("Launching...");
	labelLoadingInfo->setAttribute(Qt::WA_TranslucentBackground, false);
	
}
//--------------------------------------------------------------------------
RadianAir::~RadianAir()
{


}
//--------------------------------------------------------------------------
void RadianAir::AddLoadingCount()
{
	int resouceLoadingPercent = 0;

	if(m_FullResCount)
		resouceLoadingPercent = (int)(100.0f * (float)m_ResLoaded++ / (float)m_FullResCount);

	progressLoadingInfo->setValue(resouceLoadingPercent);

}
//--------------------------------------------------------------------------
void RadianAir::SetLoadingInfo(const std::string& currentResName)
{	
	labelLoadingInfo->setText(QString(currentResName.c_str()));
}
//--------------------------------------------------------------------------